home *** CD-ROM | disk | FTP | other *** search
/ Graphics Plus / Graphics Plus.iso / general / raytrace / renaisnc / lib.lha / Lib / mstack.h < prev    next >
Encoding:
C/C++ Source or Header  |  1992-01-04  |  1021 b   |  41 lines

  1. /*
  2. ** Definition Module: mstack
  3. ** Author: Tony DeRose
  4. ** Last Modified: 22 May 1985
  5. ** Purpose: matrix stack manipulation.
  6. */
  7.  
  8. /*
  9. ** Matrix stacks differ from regular stacks in that a push
  10. ** pre- or postmultiplies the argument with the top of the
  11. ** stack.  Premultiplication is desirable for transformation
  12. ** matrix stacks, and postmultiplication is useful for inverse
  13. ** transformation stacks.
  14. */
  15.  
  16. #define MSTACKSIZE   64        /* Maximum stack mstack size */
  17.  
  18. typedef enum {
  19.    Premultiply, Postmultiply
  20. } MstackDisipline;
  21.  
  22. typedef int *Mstack;        /* Opaque type */
  23.  
  24. extern Mstack MsCreate();    /* MsCreate(d)
  25.                    MstackDisipline d; */
  26. extern void MsPush();        /* MsPush(S,T)
  27.                    Mstack S;
  28.                    TransformType4D T; */
  29. extern void MsPop();        /* MsPop(S)
  30.                    Mstack S;*/
  31. extern TransformType4D MsTop();    /* MsTop(S)
  32.                    Mstack S;*/
  33. extern PointType4D PxTop();    /* PxTop(P,S)
  34.                    PointType4D P;
  35.                    Mstack S;*/
  36. /*extern Ray RayxTop();*/
  37. extern void MsPrint();        /* MsPrint(f,S)
  38.                    FILE *f;
  39.                    Mstack S;*/
  40.  
  41.